$(function () {
    $("#sportDg").datagrid({
        url: "sportList",
        columns:[[
            {field:'username',title:'姓名',width:100,align:'center'},
            {field:'start_time',title:'开始时间',width:100,align:'center'},
            {field:'end_time',title:'结束时间',width:100,align:'center'},
            {field:'step',title:'步数',width:100,align:'center'},
            {field:'keep_time',title:'运动时间',width:100,align:'center'},
            {field:'distance',title:'运动距离',width:100,align:'center'},
            {field:'avg_speed',title:'平均速度',width:100,align:'center'},
            {field:'start_place',title:'开始位置',width:100,align:'center'},
            {field:'end_place',title:'结束位置',width:100,align:'center'}
        ]],
        fit:true,
        fitColumns:true,
        rownumbers:true,
        pagination:true,
        singleSelect:true,
        pageSize:30,
        toolbar: '#sportTb'
    })
});